<template>
  <div class="home">
    <el-form v-if="text" :label-position="labelPosition" label-width="80px" :model="formLabelAlign">
      <el-form-item label="流程名称">
        <el-input v-model="formLabelAlign.name" />
      </el-form-item>
      <el-form-item label="流程编号">
        <el-input v-model="formLabelAlign.region" />
      </el-form-item>
      <el-form-item>
        <el-button type="primary" class="submint" icon="el-icon-edit" @click.native="onSubmit">添加</el-button>
      </el-form-item>
    </el-form>
    <addimg
      v-if="text == false"
      :img-path-name="IDPositive"
      :img-i-d="IDother"
    />
  </div>
</template>
<script>
import addimg from 'cs/addimg/addimage'

export default {
  components: { addimg },
  props: {
    imgflag: {
      type: Boolean
    }
  },
  data() {
    return {
      text: this.imgflag,
      IDPositive: this.$ENV.IDPOSITIVE,
      IDother: '1', // 用户ID
      labelPosition: 'right',
      formLabelAlign: {
        name: '',
        region: '',
        type: ''
      }
    }
  },
  computed: {
    // 计算属性
  },
  watch: {},
  created() {

  },
  mounted() {
    // 生命周期
  },
  methods: {
    onSubmit() {
      this.text = false
    }
  }
}
</script>
<style scoped>
  .home {
    width: 100%;
    height: 100%;
  }

  .submint {
    margin-left: 30%;
    /*float: right;*/
    /*margin-bottom: 10px;*/
  }

</style>
